package com.turing.post.report.impl;

import javax.ejb.Local;
import javax.ejb.Remote;
import javax.ejb.Stateless;
import javax.persistence.EntityManager;
import javax.persistence.PersistenceContext;

import com.turing.post.report.util.OnlineTransferChkAccCtl;
import com.turing.post.report.util.OnlineTransferChkAccCtlDao;
import com.turing.post.util.GeneralDao;
import com.turing.post.util.PCPSApplicationException;

@Stateless(mappedName = "account.impl.OnlineTransferChkAccCtlDaoImpl")
@Remote
@Local
public class OnlineTransferChkAccCtlDaoImpl implements
		OnlineTransferChkAccCtlDao {
	/**
	 * 实体管理器
	 * 
	 * @see javax.persistence.EntityManager
	 */
	@PersistenceContext
	protected EntityManager _em;
	
	@Override
	public OnlineTransferChkAccCtl getOnlineTransferChkAccCtl(
			OnlineTransferChkAccCtl otc) {
		return _em.find(OnlineTransferChkAccCtl.class, otc);
	}

	@Override
	public void insert(OnlineTransferChkAccCtl otc)
			throws PCPSApplicationException {
		GeneralDao.insert(_em, otc);
	}

	@Override
	public void update(OnlineTransferChkAccCtl otc)
			throws PCPSApplicationException {
		GeneralDao.update(_em, otc);
	}

}
